Verified lightweight bytecode verification

نویسندگان

  • Gerwin Klein
  • Tobias Nipkow
چکیده

The Java Virtual Machine (JVM) comprises a typed assembly language, an abstract machine for executing it, and the so-called Bytecode Verifier (BV) for checking the welltypedness of JVM programs. Resource-bounded JVM implementations on smart cards do not provide bytecode verification because of the relatively high space and time consumption. They either do not allow dynamic loading of JVM code at all or rely on cryptographic methods to ensure that bytecode verification has taken place offcard. In order to allow on-card verification, Eva and Kristoffer Rose [21] proposed a (sparse) annotation of JVM code with types to enable a one-pass verification of welltypedness. Roughly speaking, this transforms a type reconstruction problem into a type checking problem, which is easier. More precisely, the type inference problem is a data flow analysis problem that requires an iterative solution, whereas the type checking problem merely needs a single pass to check consistency of the type annotations with the code. Based on these ideas we have extended an existing formalization of the JVM in Isabelle/HOL [18, 12]. Isabelle [16] is a generic theorem prover that can be instantiated with different object logics, and Isabelle/HOL [14], simply typed higher order logic, is the most widely used of these object logics. We will first describe the general idea of bytecode verification and its formalization in Isabelle/HOL. After that we explain how lightweight bytecode verification works, how we formalized it and proved it correct and complete. The full formalization is available on the web [13].

برای دانلود رایگان متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Verified Java bytecode verification

The bytecode verifier is an important part of Java’s security architecture. This thesis presents a fully formal, executable, and machine checked specification of a representative subset of the Java Virtual Machine and its bytecode verifier together with a proof that the bytecode verifier is safe. The specification consists of an abstract framework for bytecode verification which is instantiated...

متن کامل

Lightweight verification of control flow policies on Java bytecode

This paper presents the enforcement of control flow policies for Java bytecode devoted to open and constrained devices. On-device enforcement of security policies mostly relies on run-time monitoring or inline checking code, which is not appropriate for strongly constrained devices such as mobile phones and smart-cards. We present a proof-carrying code approach with on-device lightweight verifi...

متن کامل

Formal Translation of Bytecode into BoogiePL

Many modern program verifiers translate the program to be verified and its specification into a simple intermediate representation and then compute verification conditions on this representation. Using an intermediate language improves the interoperability of tools and facilitates the computation of small verification conditions. Even though the translation into an intermediate representation i...

متن کامل

Computing Stack Maps with Interfaces

Lightweight bytecode verification uses stack maps to annotate Java bytecode programs with type information in order to reduce the verification to type checking. This paper describes an improved bytecode analyser together with algorithms for optimizing the stack maps generated. The analyser is simplified in its treatment of base values (keeping only the necessary information to ensure memory saf...

متن کامل

Bytecode Analysis for Proof Carrying Code

Out of annotated programs proof carrying code systems construct and prove verification conditions that guarantee a given safety policy. The annotations may come from various program analyzers and must not be trusted as they need to be verified. A generic verification condition generator can be utilized such that a combination of annotations is verified incrementally. New annotations may be veri...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

عنوان ژورنال:
  • Concurrency and Computation: Practice and Experience

دوره 13  شماره 

صفحات  -

تاریخ انتشار 2001